<!--
 * @description  : 案件-先行登记保存证据处理通知书文书
 * @descriptionDetail: 案件-先行登记保存证据处理通知书文书
 * @copyright    : 浙江烟草
 * @author       : sy
 * @create       : 2022-08-25 15:43:11
-->
<template>
  <view class="page">
    <!-- #ifdef H5-ONLY -->
    <theme-navbar :is-white="false" :title="navTitle" backText="返回" >
      <view class="theme-color" @click="printOrDown(state.canEdit)">
        {{ state.canEdit ? "预览" : "打印" }}
      </view>
    </theme-navbar>
    <!-- #endif -->
		<!-- #ifdef H5-WECHAT || H5-EMP -->
		<fab-button :content="state.canEdit?fContent:fContents" @fabtrigger="fabtrigger" />
		<!-- #endif -->
    <view class="main-content">
      <view style="width: calc(100% + 30px)">
        <form-section title="先行登记保存证据处理通知书"></form-section>
      </view>
      <u-form
        class="form-content"
        :model="docIns"
        :error-type="errorType"
        ref="uForm"
      >
        <u-form-item label="文书编号" :label-position="labelPosition" :required="true" prop="fullDocNo">
			<u-input placeholder="请填写文书编号" :disabled="!state.canEdit" v-model="docIns.fullDocNo" />
        </u-form-item>
        <u-form-item
          label="先保书"
          :label-width="labelWidth"
          right-icon="arrow-right"
          :label-position="labelPosition"
          :required="true"
          prop="regDocNo"
          ref="regDocRef"
        >
          <u-select
            :list="regsList"
            mode="single-column"
            v-model="importLicShow"
            @confirm="selectConfirm('goodsRegUuid','regDocNo',$event)"
          ></u-select>
          <u-input
            :clearable="false"
            :disabled="!state.canEdit"
            placeholder="请选择"
            v-model="docIns.regDocNo"
            @click="
              () => {
                if (state.canEdit) importLicShow = true;
              }
            "
          />
        </u-form-item>
        <u-form-item
          label="当事人"
          :label-position="labelPosition"
          prop="party"
          :required="true"
          right-icon="arrow-right"
        >
          <u-input
            placeholder="请输入"
            :disabled="true"
            v-model="docIns.party"
            @click="
              () => {
                if (state.canEdit) partySelectShow = true;
              }
            "
          />
        </u-form-item>
        <u-form-item
          label="案由"
          :label-position="labelPosition"
          prop="causeOfAction"
          ref="caseChangeRef"
        >
          <u-input
            type="textarea"
            height="35"
            :auto-height="true"
            placeholder=""
            :disabled="true"
            v-model="docIns.causeOfAction"
            @click="
              () => {
                if (state.canEdit) causeOfActionHandle();
              }
            "
          />
        </u-form-item>
        <u-form-item
          label="先保书日期"
          :label-width="labelWidth"
          :required="true"
          right-icon="arrow-right"
          prop="regDate"
          ref="dateChangeRef"
        >
          <u-input
            :disabled="true"
            placeholder="请选择日期"
            input-align="right"
            v-model="docIns.regDate"
            @click="
              () => {
                if (state.canEdit) isShowRegDate = true;
              }
            "
          />
        </u-form-item>
        <u-form-item
          label="先保书文号"
          :label-position="labelPosition"
          prop="regDocNo"
          :required="true"
        >
          <u-input
            placeholder="请输入"
            :disabled="!state.canEdit"
            v-model="docIns.regDocNo"
          />
        </u-form-item>
        <u-form-item
          label="处理条例"
          :required="true"
          :label-position="labelPosition"
          prop="handleDesc"
          ref="handleDescRef"
        >
          <u-checkbox-group
            :wrap="true"
            :disabled="!state.canEdit"
            :label-disabled="true"
            @change="checkboxChange"
          >
            <u-checkbox
              :name="item.value"
              v-for="(item, index) in handleList"
              :key="index"
              v-model="item.checked"
            >
              <view>
                {{ item.name }}
              </view>
              <!-- 可填写时间 -->
              <view v-if="index==1">
                <view class="check-desc">
                  送交
                  <view style="flex-shrink: 0;">
                    <u-input
                      placeholder="请输入"
                      class="u-m-l-20 u-m-r-20"
                      input-align="center"
                      :disabled="!state.canEdit"
                      v-model="docIns.handlingRegulations02"
                    />
                  </view>
                  鉴定。
                </view>
                <view class="check-desc">
                  鉴定所需时间
                  <view class="dec-input">
                    <u-input
                      placeholder="请输入"
                      class="u-m-l-20 u-m-r-20"
                      input-align="center"
                      v-model="docIns.identDeadLine"
                    />
                  </view>
                  个工作日
                </view>
              </view>
            </u-checkbox>
          </u-checkbox-group>
        </u-form-item>
        <u-form-item>
          <view class="person-info">
            <view class="p-title">
              <view class="doc-sub-title">
                承办人
              </view>
              <view
                class="uicon-sty"
                @click="
                  () => {
                    if (state.canEdit) addPerson();
                  }
                "
              >
                <u-icon
                  name="plus-circle"
                  :color="$theme.u_type_primary"
                  size="40"
                ></u-icon>
              </view>
            </view>
            <view
              class="p-content"
              v-for="(item, index) in personList"
              :key="index"
            >
              <text class="p-width">
                {{ item.personName }}
              </text>
              <text>
                {{ item.leCertNo || item.inspectionCertNo }}
              </text>
            </view>
          </view>
        </u-form-item>
        <u-form-item
          label="文书日期"
          label-width="200"
          right-icon="arrow-right"
          :required="true"
          ref="docDateChangeRef"
        >
          <u-input
            :disabled="true"
            placeholder="请选择日期"
            input-align="right"
            v-model="docIns.docDate"
            @click="
              () => {
                if (state.canEdit) isShowDocDate = true;
              }
            "
          />
        </u-form-item>
        <u-form-item
          label="送达方式"
          :required="true"
          :label-position="labelPosition"
          prop="serviceStyle"
        >
          <dic-input
            :keyWord="$u.dic.DIC_KEYS.BSC_SERVICE_TYPE"
            :dicCode="docIns.serviceStyle"
            inputAlign="left"
            type="select"
            :select-open="
              dicSelectOpen('serviceStyle', $u.dic.DIC_KEYS.BSC_SERVICE_TYPE)
            "
            placeholder="请选择"
            v-model="docIns.serviceStyleName"
            @changeInputModelData="
              (name) => {
                $set(docIns, 'serviceStyleName', name);
              }
            "
            @click="
              showDic(
                $u.dic.DIC_KEYS.BSC_SERVICE_TYPE,
                docIns.serviceStyle,
                'serviceStyle'
              )
            "
          />
        </u-form-item>
        <u-form-item
          label="送达地点"
          label-width="200"
          :required="true"
          prop="serviceAddr"
        >
          <u-input
            type='textarea'
            placeholder="请输入送达地点"
            v-model="docIns.serviceAddr"
          />
        </u-form-item>
        <!-- <u-form-item label="" :label-position="labelPosition">
          <show-goods-info
            :caseUuid="caseParam.caseUuid"
            :dataFromInit="getGoodsList"
            :hasDel="false"
            ref="goodInfoRef"
          >
          </show-goods-info>
        </u-form-item> -->
        <u-form-item :label-position="labelPosition" label="备注" prop="remark">
          <u-input
            type="textarea"
            placeholder="请填写备注"
            maxlength="1000"
            :disabled="!state.canEdit"
            v-model="docIns.remark"
          />
        </u-form-item>
      </u-form>
    </view>
    <view class="space-content"></view>
    <!-- 底部按钮开始 -->
    <view class="submit-btns btn-other-cls" v-if="state.canEdit">
      <u-button
        plain
        class="u-btn"
        type="primary"
        @click="saveOrSubmit('save')"
      >
        保存
      </u-button>
      <u-button class="u-btn" type="primary" @click="saveOrSubmit('submit')">
        提交
      </u-button>
    </view>
    <!-- 底部按钮结束 -->
    <!-- 人员选择 -->
    <u-popup mode="bottom" height="80%" v-model="personSelectShow">
      <person-selection
        :params="psParam"
        @choose="handlerChoosePerson"
      ></person-selection>
    </u-popup>
    <u-calendar
      :mode="mode"
      :max-date="maxDate"
      v-model="isShowRegDate"
      @change="changeDate('regDate', $event)"
    >
    </u-calendar>
    <u-calendar
      :mode="mode"
      :max-date="yestDate"
      v-model="isShowDocDate"
      @change="changeDate('docDate', $event)"
    >
    </u-calendar>
    <u-popup mode="bottom" height="80%" v-model="partySelectShow">
      <select-party-component
        :params="partyParams"
        @choose="handlerChooseParty"
      ></select-party-component>
    </u-popup>
    <dic-choice
      :keyWord="dicKeyWords"
      :currentSelect="dicCurrentSelect"
      v-model="dicShow"
      @confirm="selectDicConfirm"
    ></dic-choice>
  </view>
</template>
<script>
import { dateUtils, } from "@/common/util";
import PersonSelection from "@/pages/case/components/personSelection.vue";
import caseCommon from "../caseCommonMixin.js";
import DicChoice from "@/components/dic_choice.vue";
import DicInput from "@/components/dic_input.vue";
import officeService from "@/service/case/office.service.js";
import zjCommonService from "@/service/common/common.service";
// import ShowDocRegGoodsInfo from "../components/showDocRegGoodsInfo.vue";
import caseService from "@/service/case/case.service";
import SelectPartyComponent from "../components/selectPartyComponent.vue";
import FormSection from "@/components/form-section.vue";
import fabButton from '@/components/uni-fab.vue';
export default {
  components: {
    PersonSelection,
    // "show-goods-info": ShowDocRegGoodsInfo,
    SelectPartyComponent,
    FormSection,
    DicChoice,
    DicInput,
    fabButton
  },
  mixins: [caseCommon,],
  data() {
    return {
      dicShow: false, // dic_select 是否显示
      dicKeyWords: "", // dic 关键字
      dicCurrentSelect: "", // dic 当前选择项
      mode: "date",
      maxDate: "2099-12-31",
      isShowRegDate: false,
      isShowDocDate: false,
      importLicShow: false,
      labelPosition: "top",
      labelWidth: "360",
      errorType: ["border-bottom", "message",],
      personSelectShow: false,
      psParam: {},
      regsList: [], // 先保书列表
      handleList: [
        {
          name: "采取复制、拍照、录像等证据保全措施。",
          value: "1",
          checked: false,
          disabled: false,
          field: "handleDesc01",
        },
        {
          name: "",
          value: "2",
          checked: false,
          disabled: false,
          field: "handleDesc02",
        },
        {
          name: "依法移送其他有关部门处理。",
          value: "3",
          checked: false,
          disabled: false,
          field: "handleDesc03",
        },
        {
          name: "解除先行登记保存措施并发还。",
          value: "4",
          checked: false,
          disabled: false,
          field: "handleDesc04",
        },
      ],
      fContent: [{
        iconPath: require('@/static/oview.png'),
        selectedIconPath: require('@/static/oview.png'),
        text: '预览',
        active: false,
      }],
      fContents: [{
        iconPath: require('@/static/dy.png'),
        selectedIconPath: require('@/static/dy.png'),
        text: '打印',
        active: false,
      }],
      rules: {
        regDocNo: [
          {
            required: true,
            message: "请选择先保书",
            trigger: "change",
          },
        ],
        serviceAddr: [
          {
            required: true,
            message: "请输入送达地点",
            trigger: ["change", "blur",],
          },
        ],
        serviceStyle: [
          {
            required: true,
            message: "请选择送达方式",
            trigger: ["change", "blur",],
          },
        ],
        // fullDocNo: [{
        //   required: true,
        //   message: '请输入先保书文号',
        //   trigger: ['change', 'blur',],
        // },],
        regDate: [
          {
            required: true,
            message: "请选择先保书日期",
            trigger: ["change", "blur",],
          },
        ],
        docDate: [
          {
            required: true,
            message: "请选择文书日期",
            trigger: ["change", "blur",],
          },
        ],
      },
      personList: [], // 承办人
      isAction: false,
      caseParam: {}, // 文书列表中传过来的参数
      doc: {},
      docIns: {},
      docRegsInfo: [],
      selectRegs: {},
      saveData: {},
      checkIndex: 0,
      isShowSignView: false,
      signImgList: [],
      goodsList: [],
      partySelectShow: false,
      partyList: [], // 当事人列表
      partyParams: {}, // 传给当事人选择页面的参数
      yestDate: this.$u.timeFormat(Date.now()),
      goodsRegUuid: "",
    };
  },
  watch: {
    isShowDocDate() {
      this.$refs.dateChangeRef.validation();
    },
    isShowRegDate() {
      this.$refs.docDateChangeRef.validation();
    },
    isAction() {
      this.$refs.caseChangeRef.validation();
    },
  },
  created() {},
  onReady() {
    this.$refs.uForm.setRules(this.rules);
  },
  onLoad(data) {
    this.caseParam = this.getRouteParam();
  },
  mounted() {
    this.docStep((docInfo) => {
      this.doc = docInfo ? docInfo : {};
      this.setRightBtns();
    });
    this.initDocData();
  },
  methods: {
    // 设置右侧标题
    setRightBtns() {
      // #ifdef H5-DINGDING
      this.$deviceApi.setRight(
        this.state.canEdit ? "预览" : "打印",
        () => {
          this.printOrDown(this.state.canEdit);
        },
        true,
        true
      );
      // #endif
    },
    // 数据字典组件选择事件
    dicSelectOpen: function (keyWord) {
      if (this.dicKeyWords == keyWord && this.dicShow) {
        return true;
      }
      return false;
    },
    showDic: function (key, cur, fileName) {
      if (!this.state.canEdit) return;
      if (this.dicShow) return;
      this.dicKeyWords = key;
      this.dicCurrentSelect = cur;
      this.dicShow = true;
    },
    selectDicConfirm: function (e) {
      // 类型
      if (this.dicKeyWords == this.$u.dic.DIC_KEYS.BSC_SERVICE_TYPE) {
        this.docIns.serviceStyleName = e[0].label;
        this.docIns.serviceStyle = e[0].extra.bcbCode;
      }
    },
    // 初始化文书信息
    initDocData() {
      let parms = {
        id: this.caseParam.id,
        docUuid: this.caseParam.docUuid,
        bizUuid: this.caseParam.bizUuid,
      };
      let self = this;
      this.$u.loading("加载中...");
      officeService
        .docGoodsHandle(parms)
        .then((res) => {
          this.getPartyInfoList();
          // 查询可选的先保书
          officeService
            .getDoodsRegs({
              caseUuid: this.caseParam.caseUuid,
            })
            .then((regs) => {
              this.$u.hideLoading();
              let [rs, employeeList, selectReg, docRegs,] = [
                {},
                [],
                {},
                regs.data,
              ];
              if (res.success && res.data.length === 2) {
                rs = res.data[1];
                employeeList = this.parseEmployee(rs);
                rs.goodsHandleUuid = res.data[0].goodsHandleUuid;
                rs.docDate = dateUtils.dateFormat("yyyy年MM月dd日", new Date());
                // 如果只有一个先报书，则直接赋值
                if (regs.success && docRegs.length == 1) {
                  selectReg = docRegs[0];
                  rs.regDate = selectReg.regTime;
                  rs.party = selectReg.party;
                  rs.causeOfAction = selectReg.causeOfAction;
                  rs.goodsRegUuid = selectReg.goodsRegUuid;
                  rs.regDocNo = selectReg.fullDocNo;
                  rs.docYear = selectReg.docYear;
                }
              } else {
                rs = res.data[0];
                employeeList = this.parseEmployee(rs);
                selectReg =
                  docRegs.length > 0 &&
                  docRegs.filter(
                    (item) => item.goodsRegUuid == rs.goodsRegUuid
                  );
                rs.regDate = selectReg[0].regTime;
                rs.party = selectReg[0].party;
                rs.causeOfAction = selectReg[0].causeOfAction;
                rs.regDocNo = selectReg[0].fullDocNo;
              }
              this.docIns = rs;
              // 获取物品信息
              this.goodsRegUuid = rs.goodsRegUuid;
              // this.getGoodsList();
              // 处理条例回显
              this.handleList.forEach((item) => {
                if (
                  this.docIns.handleDesc01 &&
                  this.docIns.handleDesc01.indexOf(item.value) != -1
                ) {
                  item.checked = true;
                }
              });
              this.personList = employeeList;
              this.docRegsInfo = docRegs;
              // 先保书下拉框处理
              let docList = [];
              this.docRegsInfo.length > 0 &&
                this.docRegsInfo.forEach((item) => {
                  docList.push({
                    value: item.goodsRegUuid,
                    label: item.fullDocNo,
                    extra: item,
                  });
                });
              this.regsList = docList;
              this.selectRegs = selectReg;
              this.docGoodsReg = rs;
              this.personList = employeeList;
            })
            .catch((er) => {
              console.log(er);
              this.$u.hideLoading();
              this.$u.toast(er);
            });
        })
        .catch((er) => {
          console.log(er);
          this.$u.hideLoading();
          this.$u.toast(er);
        });
    },
    // 获取当事人list（多选）
    getPartyInfoList() {
      caseService
        .getPartyInfoList(this.caseParam.bizUuid)
        .then((res) => {
          if (!res.success) return;
          let names = [];
          this.partyList = res.data.length > 0 ? res.data : [];
          this.partyList.forEach((itm) => {
            if (this.docIns.partyUuids.indexOf(itm.partyUuid) != -1) {
              itm.check = true;
              names.push(itm.partyName);
            }
          });
          this.docIns.party = names.join(",");
          this.partyParams = {
            list: this.partyList,
            selUsersStr: this.docIns.partyUuids,
          };
        })
        .catch((err) => {
          this.partyList = [];
          console.log(err);
        });
    },
    // 选择当事人回调事件
    handlerChooseParty(e) {
      this.partySelectShow = false;
      this.docIns.party = e.partyNames;
      this.partyParams.selUsersStr = e.partyUuids;
      this.docIns.partyUuids = e.partyUuids;
    },
    // getGoodsList() {
    //   return new Promise((resolve) => {
    //     if (this.$u.test.isEmpty(this.goodsRegUuid)) {
    //       this.$refs["goodInfoRef"].setStaticData([]);
    //       return;
    //     }
    //     officeService
    //       .goodsList(this.goodsRegUuid)
    //       .then((rs) => {
    //         if (rs.success) {
    //           this.goodsList = rs.data;
    //           this.$refs["goodInfoRef"].setStaticData(this.goodsList);
    //         }
    //       })
    //       .catch((err) => {
    //         console.log(err);
    //         this.$refs["goodInfoRef"].setStaticData([]);
    //       });
    //   });
    // },
    // 下拉框选择
    selectConfirm(type, name, e) {
      // this.docIns[name] = '';
      // this.docIns[type] = '';
      this.docIns.regDate = e[0].extra.regTime;
      this.docIns.party = e[0].extra.party;
      this.docIns.causeOfAction = e[0].extra.causeOfAction;
      this.docIns.goodsRegUuid = e[0].extra.goodsRegUuid;
      this.docIns.regDocNo = e[0].extra.fullDocNo;
      this.docIns.docYear = e[0].extra.docYear;
      this.$refs.regDocRef.validation();
    },
    changeDate(type, e) {
      this.docIns[type] = dateUtils.dateFormat(
        "yyyy年MM月dd日",
        new Date(e.result)
      );
      if (type == "docDate") this.$refs.docDateChangeRef.validation();
      if (type == "regDate") this.$refs.dateChangeRef.validation();
    },
    // 打印/预览
    printOrDown(flag) {
      if (flag) {
        // 调接口预览
        this.saveOrSubmit("preview");
      } else {
        this.downloadFile(this.doc.pdfFileId);
      }
    },
    downloadFile(fileId, titleName, isDownload) {
      let pdfIds = fileId;
      if (!pdfIds) {
        this.$u.toast("没有文书");
        return;
      }
      this.setRouteParam({
        fileId: pdfIds,
        fileName: titleName,
        isDownload: isDownload,
      });
      this.$u.route("pages/commonPage/printerComponent");
    },
    // 添加承办人事件
    addPerson() {
      this.psParam = {
        min: 2,
        max: 2,
        caseUuid: this.caseParam.caseUuid,
      };
      this.personSelectShow = true;
    },
    handlerChoosePerson(e) {
      this.personSelectShow = false;
      this.personList = [...e,];
      let tIds = [];
      let tNames = [];
      this.personList.forEach((el) => {
        tIds.push(el.personUuid);
        tNames.push(el.personName + "(" + el.leCertNo + ")");
      });
      this.docIns["undertakerUuids"] = tIds.join(",");
      this.docIns["undertaker"] = tNames.join(",");
    },
    checkboxChange(e) {
      console.log(e);
      this.docIns.handleDesc01 = e.join(",");
    },
    // 案由点击事件
    causeOfActionHandle() {},
    // 选择案由返回列表时更新列表状态
    updateBackState(param) {
      // 案由
      if (param.caseSelectionData) {
        let [names, ids,] = [[], [], [], [],];
        param.caseSelectionData.forEach((item) => {
          names.push(item.caseProperty);
          ids.push(item.casepropUuid);
        });
        this.$set(this.docIns, "causeOfAction", names.join(","));
        this.$set(this.docIns, "casepropIds", ids.join(","));
        this.isAction = false;
      }
    },
    // 表单验证
    validForm() {
      let basicValid = false;
      this.$refs.uForm.validate((valid) => {
        if (valid) {
          if (!this.docIns.partyUuids) {
            this.$u.toast("请选择当事人!");
            return;
          }
          basicValid = true;
        } else {
          basicValid = false;
        }
      });
      return basicValid;
    },
    // 保存或提交
    saveOrSubmit(type) {
      if (type == "preview") {
        if (!this.doc.isRecorded) {
          this.$u.toast("请先保存数据");
          return;
        }
        officeService
          .buildLocalPunish("/record/doc-goods-handle", this.doc.docInsUuid)
          .then((pdfId) => {
            if (pdfId.success) {
              this.downloadFile(pdfId.bean, "预览", false);
            } else {
              this.$u.toast(pdfId.msg);
            }
          });
      } else {
        let flag = this.validForm();
        if (flag) {
          if (this.personList.length == 0) {
            this.$u.toast("请选择承办人!");
            return;
          }
          let filterList = this.handleList.filter((item) => item.checked);
          if (filterList.length == 0) {
            this.$u.toast("请至少选择一个处理条例!");
            return;
          }
          if (!this.docIns.docNo) {
            this.$u.toast("文书编号不能为空!");
            return;
          }
          if (!this.docIns.docYear) {
            this.$u.toast("文书年份不能为空!");
            return;
          }
          if (this.docIns.docNo.length > 20) {
            this.$u.toast("文书编号请输入20位以内的字符!");
            return;
          }
          if (this.docIns.docYear.length > 4) {
            this.$u.toast("文书年份请输入4位数之内!");
            return;
          }

          this.handleOperBtn(type);
        }
      }
    },
    fabtrigger(btn) {
      if (btn.index == 0) {
        this.printOrDown(this.state.canEdit);
      }
    },
    handleOperBtn(flag) {
      let [docGoodsReg, self,] = [this.docIns, this,];
      let {
        docUuid,
        id,
        titemUuid,
        type,
        bizUuid,
        caseCode,
        caseType,
        gfaCode,
      } = this.caseParam;
      docGoodsReg.caseUuid = this.caseParam.caseUuid;
      flag === "save" && this.$u.loading("数据保存中...");
      officeService
        .saveDocGHandle(docGoodsReg, docUuid, titemUuid, id, type)
        .then((res) => {
          this.$u.hideLoading();
          if (res.success) {
            this.$u.toast(res.msg);
            let bean = res.bean;
            docGoodsReg.goodsHandleUuid = bean.goodsHandleUuid;
            this.saveData = res.data[0];
            self.doc["isRecorded"] = res.data[0].isRecorded;
            self.doc["docInsUuid"] = res.data[0].docInsUuid;
            this.docIns = docGoodsReg;
            if (flag === "submit") {
              this.$u.loading("数据提交中...");
              officeService
                .submitDocHandle(bean, docUuid, titemUuid)
                .then((res) => {
                  this.$u.hideLoading();
                  this.saveBehaviorLog(1, this.caseParam, this.doc);
                  if (res.success) {
                    // 返回列表
                    this.$u.toast(res.msg);
                    self.backPrev({
                      paramKey: "offiList",
                      param: {
                        caseUuid: bizUuid,
                        caseCode: caseCode,
                        caseType: caseType,
                      },
                    });
                  } else {
                    this.$u.toast(res.msg);
                  }
                })
                .catch((er) => {
                  console.log(er);
                  this.$u.hideLoading();
                  this.$u.toast(er);
                });
            } else {
              this.saveBehaviorLog(0, this.caseParam, this.doc);
            }
          } else {
            this.$u.toast(res.msg);
          }
        });
    },
  },
};
</script>

<style lang="scss" scoped>
@import "../case_common.scss";

.page {
  padding: 0;
}

.doc-no {
  display: inline-block;
  height: 35px;
  width: 60px;
  text-align: center !important;
  flex: none;
}

.check-desc {
  display: flex;
  align-items: center;

  .dec-input {
    width: 25%;
  }
}
</style>
